
<!DOCTYPE html>

<html lang="en">
  <head>
    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>About &#8212; Boost.HigherOrderFunctions 0.6 documentation</title>
    <link rel="stylesheet" type="text/css" href="../../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../../_static/boostbook.css" />
    <script data-url_root="../../" id="documentation_options" src="../../_static/documentation_options.js"></script>
    <script src="../../_static/jquery.js"></script>
    <script src="../../_static/underscore.js"></script>
    <script src="../../_static/_sphinx_javascript_frameworks_compat.js"></script>
    <script src="../../_static/doctools.js"></script>
    <script src="../../_static/sphinx_highlight.js"></script>
    <link rel="index" title="Index" href="../../genindex.html" />
    <link rel="search" title="Search" href="../../search.html" />
    <link rel="next" title="Building" href="building.html" />
    <link rel="prev" title="Introduction" href="intro.html" /> 
  </head><body>
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86"src="../../_static/boost.png"></td>
</tr></table>

<div class="spirit-nav">
<a accesskey="p"  href="intro.html"><img src="../../_static/prev.png" alt="Prev"></a>
<a accesskey="u" href="intro.html"><img src="../../_static/up.png" alt="Up"></a>
<a accesskey="h" href="../index.html"><img src="../../_static/home.png" alt="Home"></a>
<a accesskey="n"  href="building.html"><img src="../../_static/next.png" alt="Next"></a>
</div>
  

    <div class="document">
  <div class="chapter">
      <div class="body" role="main">
        
  <!-- Copyright 2018 Paul Fultz II
     Distributed under the Boost Software License, Version 1.0.
     (http://www.boost.org/LICENSE_1_0.txt)
-->
<div class="section" id="about">
<h1>About<a class="headerlink" href="#about" title="Permalink to this heading">¶</a></h1>
<p>HigherOrderFunctions is a header-only C++11/C++14 library that provides utilities for functions and function objects, which can solve many problems with much simpler constructs than whats traditionally been done with metaprogramming.</p>
<p>HigherOrderFunctions is:</p>
<ul class="simple">
<li><p>Modern: HigherOrderFunctions takes advantages of modern C++11/C++14 features. It support both <code class="docutils literal notranslate"><span class="pre">constexpr</span></code> initialization and <code class="docutils literal notranslate"><span class="pre">constexpr</span></code> evaluation of functions. It takes advantage of type deduction, varidiac templates, and perfect forwarding to provide a simple and modern interface.</p></li>
<li><p>Relevant: HigherOrderFunctions provides utilities for functions and does not try to implement a functional language in C++. As such, HigherOrderFunctions solves many problems relevant to C++ programmers, including initialization of function objects and lambdas, overloading with ordering, improved return type deduction, and much more.</p></li>
<li><p>Lightweight: HigherOrderFunctions builds simple lightweight abstraction on top of function objects. It does not require subscribing to an entire framework. Just use the parts you need.</p></li>
</ul>
<p>HigherOrderFunctions is divided into three components:</p>
<ul class="simple">
<li><p>Function Adaptors and Decorators: These enhance functions with additional capability.</p></li>
<li><p>Functions: These return functions that achieve a specific purpose.</p></li>
<li><p>Utilities: These are general utilities that are useful when defining or using functions</p></li>
</ul>
<p>Github: <a class="reference external" href="https://github.com/pfultz2/higherorderfunctions/">https://github.com/pfultz2/higherorderfunctions/</a></p>
<p>Documentation: <a class="reference external" href="http://pfultz2.github.io/higherorderfunctions/doc/html/">http://pfultz2.github.io/higherorderfunctions/doc/html/</a></p>
</div>
<div class="section" id="motivation">
<h1>Motivation<a class="headerlink" href="#motivation" title="Permalink to this heading">¶</a></h1>
<ul class="simple">
<li><p>Improve the expressiveness and capabilities of functions, including first-class citzens for function overload set, extension methods, infix operators and much more.</p></li>
<li><p>Simplify constructs in C++ that have generally required metaprogramming</p></li>
<li><p>Enable point-free style programming</p></li>
<li><p>Workaround the limitations of lambdas in C++14</p></li>
</ul>
</div>
<div class="section" id="requirements">
<h1>Requirements<a class="headerlink" href="#requirements" title="Permalink to this heading">¶</a></h1>
<p>This requires a C++11 compiler. There are no third-party dependencies. This has been tested on clang 3.5-3.8, gcc 4.6-7, and Visual Studio 2015 and 2017.</p>
<div class="section" id="contexpr-support">
<h2>Contexpr support<a class="headerlink" href="#contexpr-support" title="Permalink to this heading">¶</a></h2>
<p>Both MSVC and gcc 4.6 have limited constexpr support due to many bugs in the implementation of constexpr. However, constexpr initialization of functions is supported when using the <a class="reference internal" href="../../include/boost/hof/function.html#boost-hof-static-function"><span class="std std-ref"><code class="docutils literal notranslate"><span class="pre">BOOST_HOF_STATIC_FUNCTION</span></code></span></a> and <a class="reference internal" href="../../include/boost/hof/lambda.html#boost-hof-static-lambda-function"><span class="std std-ref"><code class="docutils literal notranslate"><span class="pre">BOOST_HOF_STATIC_LAMBDA_FUNCTION</span></code></span></a> constructs.</p>
</div>
<div class="section" id="noexcept-support">
<h2>Noexcept support<a class="headerlink" href="#noexcept-support" title="Permalink to this heading">¶</a></h2>
<p>On older compilers such as gcc 4.6 and gcc 4.7, <code class="docutils literal notranslate"><span class="pre">noexcept</span></code> is not used due to many bugs in the implementation. Also, most compilers don’t support deducing <code class="docutils literal notranslate"><span class="pre">noexcept</span></code> with member function pointers. Only newer versions of gcc(4.9 and later) support this.</p>
</div>
</div>


      </div>
  </div>
      <div class="clearer"></div>
    </div>
    <div class="footer" role="contentinfo">
    <table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
    <td align="left"></td>
    <td align="right"><div class="copyright-footer">
            &#169; Copyright 2016, Paul Fultz II.
        
          Created using <a href="http://sphinx-doc.org/">Sphinx</a> 5.2.1.
          <p>Distributed under the Boost Software License, Version 1.0.
          (See accompanying file <code class="filename">LICENSE_1_0.txt</code> or copy at 
          <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
          </p>
    </div></td>
    </tr></table>
    </div>
  </body>
</html>